<?php


/**
 * 前后台通用功能路由组
 */
Route::group(['namespace' => 'Coms', 'prefix' => 'coms'], function () {

    //后台登录验证码
    Route::get('/admin-code', ['as' => 'coms.admin-code', 'uses' => 'ComsController@adminCode']);
    //前台登录验证码
    Route::get('/user-code', ['as' => 'coms.user-code', 'uses' => 'ComsController@userCode']);
});

/**
 * 系统默认主页(登录页)
 */
Route::group(['middleware' => ['web_base']], function () {
//    发送通用短信验证码
//    Route::any('/send-common-code/{tel?}/{flag?}', ["as" => "send.common.code", "uses" => "Coms\\ComsController@sendCommonCode"]);
//    发送通用邮件验证码
//    Route::any('/send-common-email/{email?}', ["as" => "send.common.email", "uses" => "Coms\\ComsController@sendCommonEmailCode"]);
//    Route::any('/web/address_change', ['as' => 'web.address_change', 'uses' => 'FrontEnd\\ProductController@addressChange']);
    //首页
    Route::get('//{id?}', ['as'=>"login.page",'uses'=>"FrontEnd\\FrontEndController@loginPage"]);
//    Route::get('/login/{id}', ["as" => "login.page", "uses" => "FrontEnd\\FrontEndController@loginPage"]);
    //内容页
    Route::get('/view',['as' => "web.view", 'uses'=>"FrontEnd\\FrontEndController@viewPage"]);
    //转换路由
    Route::any('/switch-route/{id}', ['as' => 'switch.route', 'uses' => 'FrontEnd\\FrontEndController@switchRoute']);




    Route::any('/login-act', ["as" => "login.act", "uses" => "FrontEnd\\FrontEndController@loginAct"]);
    Route::any('/find-pass-page', ["as" => "login.find.page", "uses" => "FrontEnd\\FrontEndController@findPassPage"]);
    Route::any('/send-code/{name?}/{tel?}', ["as" => "send.code", "uses" => "FrontEnd\\FrontEndController@sendCode"]);//密码找回短信验证码发送
    Route::any('/find-pass-act', ["as" => "login.find.act", "uses" => "FrontEnd\\FrontEndController@findPassAct"]);

////    公共注册页面
    Route::get('/reg-page/{no?}', ['as' => 'reg.page', 'uses' => 'FrontEnd\\FrontEndController@registerPage']);
    Route::post('/reg-act', ['as' => 'reg.act', 'uses' => 'FrontEnd\\FrontEndController@registerAct']);

//    生成二维码
    Route::get('/produce-qrcode', ['as' => 'produce.qrcode', 'uses' => 'FrontEnd\\UserController@produceQrcode']);

    Route::get('/login-theme', function () {
        return view('system.login-theme');
    });

    /**
     * iqstructs新前台界面
     */
//    Route::group(['namespace' => 'FrontEnd', 'prefix' => 'web', 'middleware' => ['auth_user']], function () {

        Route::any('/center', ['as' => 'web.center', 'uses' => 'UserController@centerPage']);
//        //获取文章/公告详情
//        Route::get('/ajax/content/{flag?}/{id?}', ['as' => 'web.content', 'uses' => 'ContentController@contentDetail']);
//        //个人信息管理
//        Route::any('/me-info', ['as' => 'web.information', 'uses' => 'UserController@myInfoPage']);
//        Route::any('/me-info/save/{id}', ['as' => 'web.information.save', 'uses' => 'UserController@myInfoSave']);
//        Route::any('/modify-pass', ['as' => 'web.pass', 'uses' => 'UserController@modifyPassPage']);
//        Route::any('/modify-pass/save', ['as' => 'web.pass.save', 'uses' => 'UserController@modifyPassSave']);
//
//        //会员覆盖升级
//        Route::any('/up-user', ['as' => 'web.up-user', 'uses' => 'UserController@upUserPage']);
//        Route::any('/vip-up/save', ['as' => 'web.up-user.save', 'uses' => 'UserController@upUserSave']);
//        //会员提现
//        Route::any('/withdraw', ['as' => 'web.withdraw', 'uses' => 'UserController@withdrawPage']);
//        Route::any('/withdraw-act', ['as' => 'web.withdraw.act', 'uses' => 'UserController@withdrawAct']);
//        Route::any('/with-logs/{index?}', ['as' => 'web.withdraw.log', 'uses' => 'UserController@withdrawLogPage']);
//        Route::any('/with-cancel/{id?}', ['as' => 'web.withdraw.cancel', 'uses' => 'UserController@withdrawLogCancel']);
//
//        //会员操作
//        Route::any('/users/{index?}', ['as' => 'web.users', 'uses' => 'UserController@usersPage']);
//        Route::any('/sys-reg-page/{nid?}', ['as' => 'web.reg.page', 'uses' => 'UserController@regUserPage']);
//        Route::any('/reg-act', ['as' => 'web.reg.act', 'uses' => 'UserController@registerAct']);
//        Route::any('/act-user/{id}/{in_token?}', ['as' => 'web.users.activation', 'uses' => 'UserController@activationUser']);
//        Route::any('/del-user/{id}/{in_token?}', ['as' => 'web.users.del', 'uses' => 'UserController@delUserAct']);
//        Route::any('/act-user-list/{index?}', ['as' => 'web.active-users.list', 'uses' => 'UserController@actUserList']);
//        Route::any('/p-user-list/{index?}', ['as' => 'web.p-users.list', 'uses' => 'UserController@pUserList']);
//        Route::any('/bonus/{index?}', ['as' => 'web.bonus', 'uses' => 'UserController@bonusPage']);
//        Route::any('/shopping/{index?}', ['as' => 'web.shopping', 'uses' => 'UserController@shoppingPage']);
//        Route::any('/sys-exit', ['as' => 'sys.login.exit', 'uses' => 'UserController@exitAct']);
//
//        //会员转账
//        Route::any('/transfer', ['as' => 'web.transfer', 'uses' => 'UserController@transferPage']);
//        Route::any('/tran-act', ['as' => 'web.transfer.act', 'uses' => 'UserController@transferAct']);
//        Route::any('/tran-logs/{index?}', ['as' => 'web.transfer.log', 'uses' => 'UserController@tranLogPage']);
//
//        //币种转换
//        Route::any('/switch-coin', ['as' => 'web.switch.coin', 'uses' => 'UserController@switchCoinPage']);
//        Route::any('/switch-coin-act', ['as' => 'web.switch.coin-act', 'uses' => 'UserController@switchCoinAct']);
//        Route::any('/switch-logs/{index?}', ['as' => 'web.switch.log', 'uses' => 'UserController@switchLogPage']);
//
//        //打款申请
//        Route::any('/remit-apply', ['as' => 'web.remit.apply', 'uses' => 'UserController@remitApply']);
//        Route::any('/remit-save', ['as' => 'web.remit.save', 'uses' => 'UserController@remitSave']);
//        Route::any('/remit-logs/{index?}', ['as' => 'web.remit.logs', 'uses' => 'UserController@remitLogs']);
//        Route::any('/remit-apply-page/{id?}', ['as' => 'web.remit.apply.page', 'uses' => 'UserController@remitApplyPage']); //充值界面
//        Route::any('/remit-has-pay/{id?}', ['as' => 'web.remit.has.pay', 'uses' => 'UserController@remitHasPay']); //我已打款
//        //报单中心
//        Route::any('/apply-bdzx', ['as' => 'web.bdzx', 'uses' => 'UserController@bdzxPage']);
//        Route::any('/bdzx-act', ['as' => 'web.bdzx.act', 'uses' => 'UserController@bdzxAct']);
//        Route::get('/bdzx-log/{id?}', ['as' => 'web.bdzx.log', 'uses' => 'UserController@bdzxLog']);
//
//        //会员关系图
//        Route::any('/node-tree/{uid?}', ['as' => 'web.node.tree', 'uses' => 'UserController@nodeTreePage']);
//        Route::any('/node-zTree', ['as' => 'web.node.zTree', 'uses' => 'UserController@zTreePage']);
//
//        //在线购物商城
//        Route::any('/products/{index?}', ['as' => 'web.products', 'uses' => 'ProductController@productsPage']);//购物页面
//        //购物详情页面
//        Route::any('/product_detail/{id?}', ['as' => 'web.product_detail', 'uses' => 'ProductController@productDetail']);
//
//        Route::any('/carts', ['as' => 'web.carts', 'uses' => 'ProductController@cartsPage']);
//        Route::any('/orders/{index?}', ['as' => 'web.orders', 'uses' => 'ProductController@ordersPage']);
//        Route::any('/express-info/{oid?}', ['as' => 'web.express.info', 'uses' => 'ProductController@expressInfo']);
//        Route::any('/address', ['as' => 'web.address', 'uses' => 'ProductController@addressPage']);
//
//        Route::any('/addr-save', ['as' => 'web.address.save', 'uses' => 'ProductController@addrSave']);
//        Route::any('/add-cart', ['as' => 'web.cart.add', 'uses' => 'ProductController@addCart']);
//        Route::any('/del-cart/{no?}', ['as' => 'web.cart.del', 'uses' => 'ProductController@delCart']);
//
//        //支付页面
//        Route::any('/pay-cart', ['as' => 'web.cart.pay', 'uses' => 'ProductController@orderCreate']);
//
//
//        //关于我们
//        Route::any('/news/{flag}/{index?}', ['as' => 'web.news', 'uses' => 'ContentController@newsPage']);
//        Route::any('/feedback/{index?}', ['as' => 'web.feedback', 'uses' => 'ContentController@feedbackPage']);
//        Route::any('/feedback-send', ['as' => 'web.feedback.send', 'uses' => 'ContentController@feedbackSend']);
//
//        //虚拟货币系统
//        Route::any('/stock', ['as' => 'web.stock', 'uses' => 'StockController@stockPage']);
//        Route::any('/sale/stock', ['as' => 'web.sale.list', 'uses' => 'StockController@saleStockPage']);
//        Route::any('/buy/stock', ['as' => 'web.buy.stock', 'uses' => 'StockController@buyStockPage']);
//        Route::any('/trade-record/stock', ['as' => 'web.trade.record', 'uses' => 'StockController@tradeRecordStockPage']);
//
//
//    });


});
